package com.p2p.auth.domain.entity;

import lombok.Data;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.EntityListeners;
import javax.persistence.Table;

import org.springframework.data.jpa.domain.support.AuditingEntityListener;

import java.math.BigDecimal;

/**
 * Created by Antinomy on 16/10/13.
 */
@Entity
@Table(name = "t_user_auth")
@DynamicInsert
@DynamicUpdate
@EntityListeners(AuditingEntityListener.class)
@Data
public class User extends IdEntity {

    /**
     *
     */
    private static final long serialVersionUID = -3258839839160856613L;

    /**
     * 用户ID
     */
    @Column(columnDefinition = "varchar(50) NOT NULL comment '用户ID'")
    private String userId;


    /**
     * 姓名
     */
    private String realName;

    /**
     * 手机号码
     */
    private String phoneNum;

    /**
     * 密码
     */
    private String passWord;

    /**
     * 账户余额
     */
    private BigDecimal balance;

    /**
     * 已返利金额
     */
    private BigDecimal rebate;

    /**
     * 年纪
     */
    private Integer age;

    /**
     * 营销金额
     */
    private BigDecimal marketingAmonut;

    /**
     * 邀请人手机号
     */
    private String 	invitePhoneNum;
    /**
     * 是否绑卡
     */
    private Integer tieCard;

    /**
     * 支付方式id
     */
    private Integer paymentId;

    /**
     * 注册电商id
     */
    private String  retailersId;

    /**
     * 注册电商id
     */
    private String  retailersNo ;

    /**
     * 注册电商名称
     */
    private String retailersName ;

    //状态
    public Integer status;

    //备注
    public String remark;

    /**
     * 是否是内部员工
     */
    public Integer isInside;

    /**
     * 是否离职
     */
    public Integer onType;

}
